<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Support\Facades\DB;

class System extends Model
{
    //
    const TABLE = 'params';

    public function getParams($type)
    {
        $list = DB::table(self::TABLE)->select('key', 'value')->where([['type', '=', $type], ['is_effect', '=', '1']])->get();
        return $list;
    }
}
